<!-- directive:title 单选框复选框的各种幺蛾子事情 -->
<!-- directive:breadcrumb 单选框复选框 -->
<div class='panel-body'>
    <div class="row">
        <div class="col-sm-6">
            <div class='panel panel-default'>
                <div class='panel-heading'> 普通的单选框 </div>
                <div class='panel-body'>
                    <p>user2 = {{user2}}</p>
                    <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2'> <i></i> 门店管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="2"> <i></i> 会员卡管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="3"> <i></i> 课程管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="4"> <i></i> 数据汇总 </label>
                    <script type="text/xianjs" ui-bs>
                        <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2'> <i></i> 门店管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="2"> <i></i> 会员卡管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="3"> <i></i> 课程管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="radio" ng-model='user2' value="4"> <i></i> 数据汇总 </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> ng-repeat/ng-if 都会使单选框绑定不上 </div>
                <div class='panel-body'>
                    <p>事实上是只要是重新渲染的结构<code>都</code>和原来绑定不上</p>
                    <p>user3 = {{user3}}</p>
                    <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                        <input type="radio" ng-model='user3' value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                            <input type="radio" ng-model='user3' value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> "对象" 可以使单选框绑定上 </div>
                <div class='panel-body'>
                    <p>obj.user3 = {{obj.user3}}</p>
                    <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                        <input type="radio" ng-model='obj.user3' value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                            <input type="radio" ng-model='obj.user3' value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 赋值为数字时候初始化选择不上 (操作到是可以) </div>
                <div class='panel-body'>
                    <p>obj.user4 = {{obj.user4}}</p>
                    <label ng-repeat="row2 in roles3" class="checkbox-inline i-checks">
                        <input type="radio" ng-model='obj.user4' value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                            <input type="radio" ng-model='obj.user4' value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 指令 <code>convertToNumber</code> 可以解决这个问题 </div>
                <div class='panel-body'>
                    <p>obj.user4 = {{obj.user4}}</p>
                    <label ng-repeat="row2 in roles3" class="checkbox-inline i-checks">
                        <input type="radio" ng-model='obj.user4' convert-to-number value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles3" class="checkbox-inline i-checks">
                            <input type="radio" ng-model='obj.user4' convert-to-number value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 开关 单选框/复选框 (单选框不行) </div>
                <div class='panel-body'>
                    <p>user2 = {{user2}}</p>
                    <label class="checkbox-inline i-switch"> <input type="radio" ng-model='user2'> <i></i> </label>
                    <label class="checkbox-inline i-switch"> <input type="radio" ng-model='user2'> <i></i> </label>
                    <label class="checkbox-inline i-switch"> <input type="checkbox" ng-model='user2'> <i></i> </label>
                    <label class="checkbox-inline i-switch"> <input type="checkbox" ng-model='user2'> <i></i> </label>
                    <script type="text/xianjs" ui-bs>
                        <label class="checkbox-inline i-switch"> <input type="radio" ng-model='user2'> <i></i> </label>
                        <label class="checkbox-inline i-switch"> <input type="radio" ng-model='user2'> <i></i> </label>
                        <label class="checkbox-inline i-switch"> <input type="checkbox" ng-model='user2'> <i></i> </label>
                        <label class="checkbox-inline i-switch"> <input type="checkbox" ng-model='user2'><i></i> </label>
                    </script>
                </div>
            </div>
        </div>
        <div class="col-sm-6">
            <div class='panel panel-default'>
                <div class='panel-heading'> 普通的复选框 </div>
                <div class='panel-body'>
                    <p>user22 = {{user22}}</p>
                    <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.a'> <i></i> 门店管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.b' value="2"> <i></i> 会员卡管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.c' value="3"> <i></i> 课程管理 </label>
                    <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.d' value="4"> <i></i> 数据汇总 </label>
                    <script type="text/xianjs" ui-bs>
                        <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.a'> <i></i> 门店管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.b' value="2"> <i></i> 会员卡管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.c' value="3"> <i></i> 课程管理 </label>
                        <label class="checkbox-inline i-checks"> <input type="checkbox" ng-model='user22.d' value="4"> <i></i> 数据汇总 </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 复选框的modal应该简单一些 </div>
                <div class='panel-body'>
                    看这里 || <a ui-sef="app.form.checklist">改变checkbox的model格式</a>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> ng-repeat/ng-if 都会使单选框绑定不上 </div>
                <div class='panel-body'>
                    <p>user3 = {{user3}}</p>
                    <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                        <input type="checkbox" ng-model='user3' value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                            <input type="checkbox" ng-model='user3' value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> "对象" 可以使单选框绑定上 </div>
                <div class='panel-body'>
                    <p>obj.user3 = {{obj.user3}}</p>
                    <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                        <input type="checkbox" ng-model='obj.user3' value="{{row2.id}}">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2" class="checkbox-inline i-checks">
                            <input type="checkbox" ng-model='obj.user3' value="{{row2.id}}">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 处理下传参01问题 </div>
                <div class='panel-body'>
                    <p>obj.user5 = {{obj.user5}}</p>
                    <label ng-repeat="row2 in roles2 track by $index" class="checkbox-inline i-checks">
                        <input type="checkbox" ng-model='obj.user5[$index]' ng-true-value="1" ng-false-value="0">
                        <i></i> {{row2.text}}
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <label ng-repeat="row2 in roles2 track by $index" class="checkbox-inline i-checks">
                            <input type="checkbox" ng-model='obj.user5[$index]' ng-true-value="1" ng-false-value="0">
                            <i></i> {{row2.text}}
                        </label>
                    </script>
                </div>
            </div>
            <div class='panel panel-default'>
                <div class='panel-heading'> 如果复选框是开关 需要在判断后置状态 </div>
                <div class='panel-body'>
                    <p>user24 = {{user24}}</p>
                    <div class="checkbox-inline i-checks" ng-click="o66()">
                        <input type="checkbox" ng-checked='user24.a'>
                        <i></i> 开关
                    </div>
                    <label class="checkbox-inline i-checks">
                        <input type="checkbox" ng-model='user24.b'>
                        <i></i> 允许改动开关
                    </label>
                    <script type="text/xianjs" ui-bs>
                        <div class="checkbox-inline i-checks" ng-click="o66()">
                            <input type="checkbox" ng-checked='user24.a'>
                            <i></i> 开关
                        </div>
                        <label class="checkbox-inline i-checks">
                            <input type="checkbox" ng-model='user24.b'>
                            <i></i> 允许改动开关
                        </label>
                    </script>
                </div>
            </div>
        </div>
    </div>
</div>
